package com.ocean.filter.config;

import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.config.annotation.CorsRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;

@Configuration
public class CorsConfig implements WebMvcConfigurer {
    @Override
    public void addCorsMappings(CorsRegistry registry){
        registry.addMapping("/**")
                .allowedOrigins("http://110.40.187.129","http://127.0.0.1","http://127.0.0.1:8080","http://110.40.187.129:80")
                .allowedMethods("*")
                .allowedHeaders("*")
                .allowCredentials(true);
    }
}
